﻿Ext.define('SenchaApp.view.CarDetails', {
    extend: 'Ext.Panel',
    alias: 'widget.cardetailscontainer',
    layout: {
        type: 'vbox',
        align: 'stretch',
        pack: 'start',
    },
    action: 'carDetailsMainContainer',
    items: [
        {
            xtype: 'toolbar',
            flex:1,
            items:[
            {
                xtype: 'button',
                action: 'saveidbutton',
                text: 'Update'
            }]
        },
        {
            xtype: 'form',
            action: 'carDetails',
            flex: 8,
            bodyPadding: 5,
            layout: 'form',
            defaultType: 'textfield',
            items: [{
                xtype: 'hidden',
                autoCreateField: true,
                fieldLabel: 'Id',
                name: 'Id',
                allowBlank: false
            }, {
                fieldLabel: 'Name',
                name: 'Name',
                allowBlank: false
            }, {
                fieldLabel: 'Brand Name',
                name: 'BrandName',
                allowBlank: false
            }, {
                fieldLabel: 'Car Type',
                name: 'CarType',
                allowBlank: false
            }, {
                fieldLabel: 'Model',
                name: 'Model',
                allowBlank: false
            }, {
                fieldLabel: 'Price',
                name: 'Price',
                allowBlank: false
            }]
        }
    ]
});